package com.igame.config;

import com.fasterxml.jackson.databind.ObjectMapper;
import org.springframework.data.redis.serializer.Jackson2JsonRedisSerializer;

public class CustomJackson2JsonRedisSerializer<T> extends Jackson2JsonRedisSerializer {
    private final ObjectMapper objectMapper;
    public CustomJackson2JsonRedisSerializer(Class<T> type, ObjectMapper objectMapper) {
        super(type);
        this.objectMapper = objectMapper;
        this.setObjectMapper(objectMapper); // 设置 ObjectMapper
    }
}
